<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.prime.com.tr/ui" template="template.xhtml">
	<head>

	</head>
	<ui:define name="container">
		<h:form prependId="false">		
			<p:panel header="Alterar Senha" toggleable="true" closable="true"
				toggleSpeed="500">
				<h:panelGrid id="campos" columns="2">
					<h:outputLabel value="Login:" />
					<p:inputText disabled="true" value="#{usuarioMB.usuario.login}" />
					<h:outputLabel value="Senha Atual:" />
					<p:password id="senhaAtual" minLength="16"
						feedback="false" value="#{usuarioMB.senhaAntiga}" />
					<h:outputLabel value="Nova senha:" />
					<p:password id="novaSenha"  minLength="16"
						promptLabel="Digite uma senha segura" goodLabel="Boa"
						weakLabel="Fraca" strongLabel="Excelente"
						value="#{usuarioMB.novaSenha}" />
					<h:outputLabel value="Confirmação nova senha:" />
					<p:password id="confirmacaoSenha"  minLength="16"
						feedback="false" value="#{usuarioMB.confirmaSenha}" />
				</h:panelGrid>
				<h:panelGrid id="acao" columns="5">
					<p:commandButton id="cmdSalvar" value="Salvar" image="cmdGravar"
						action="#{usuarioMB.alterarSenha}" update="msgs, campos" />
					<p:button outcome="default.jsf" value="Fechar" image="cmdFechar"/>
				</h:panelGrid>
			</p:panel>
		</h:form>
	</ui:define>
	<ui:define name="dialog">
		
	</ui:define>
</ui:composition>
